<template>
  <div>
    <img :src="logoImage">
    <p><input type="text" v-model="username" ></p>
    <p>{{ username }}</p>
    <hr>
    <counter></counter>
  </div>
</template>

<script>
// 将图片作为模块来导入
import image from '@/assets/logo.png';

// 导入其它组件
import Counter from '@/components/Counter.vue';

export default {
  name: 'App',
  data(){
    return {
      logoImage: image ,
      username: ''
    }
  },
  components: {
    'counter': Counter
  }
}
</script>

<style>
#app {
  font-family: Avenir, Helvetica, Arial, sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-align: center;
  color: #2c3e50;
  margin-top: 60px;
}
</style>
